3.4.42 \(\int \sec ^3(e+f x) (a+a \sec (e+f x))^m \, dx\) [342]

Optimal. Leaf size=155 \[ -\frac {(a+a \sec (e+f x))^m \tan (e+f x)}{f \left (2+3 m+m^2\right )}+\frac {2^{\frac {1}{2}+m} \left (1+m+m^2\right ) \, _2F_1\left (\frac {1}{2},\frac {1}{2}-m;\frac {3}{2};\frac {1}{2} (1-\sec (e+f x))\right ) (1+\sec (e+f x))^{-\frac {1}{2}-m} (a+a \sec (e+f x))^m \tan (e+f x)}{f (1+m) (2+m)}+\frac {(a+a \sec (e+f x))^{1+m} \tan (e+f x)}{a f (2+m)} \]

[Out]

-(a+a*sec(f*x+e))^m*tan(f*x+e)/f/(m^2+3*m+2)+2^(1/2+m)*(m^2+m+1)*hypergeom([1/2, 1/2-m],[3/2],1/2-1/2*sec(f*x+
e))*(1+sec(f*x+e))^(-1/2-m)*(a+a*sec(f*x+e))^m*tan(f*x+e)/f/(m^2+3*m+2)+(a+a*sec(f*x+e))^(1+m)*tan(f*x+e)/a/f/
(2+m)

________________________________________________________________________________________

Rubi [A]
time = 0.14, antiderivative size = 155, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 5, integrand size = 21, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.238, Rules used = {3885, 4086, 3913, 3912, 71} \begin {gather*} \frac {2^{m+\frac {1}{2}} \left (m^2+m+1\right ) \tan (e+f x) (\sec (e+f x)+1)^{-m-\frac {1}{2}} (a \sec (e+f x)+a)^m \, _2F_1\left (\frac {1}{2},\frac {1}{2}-m;\frac {3}{2};\frac {1}{2} (1-\sec (e+f x))\right )}{f (m+1) (m+2)}-\frac {\tan (e+f x) (a \sec (e+f x)+a)^m}{f \left (m^2+3 m+2\right )}+\frac {\tan (e+f x) (a \sec (e+f x)+a)^{m+1}}{a f (m+2)} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[Sec[e + f*x]^3*(a + a*Sec[e + f*x])^m,x]

[Out]

-(((a + a*Sec[e + f*x])^m*Tan[e + f*x])/(f*(2 + 3*m + m^2))) + (2^(1/2 + m)*(1 + m + m^2)*Hypergeometric2F1[1/
2, 1/2 - m, 3/2, (1 - Sec[e + f*x])/2]*(1 + Sec[e + f*x])^(-1/2 - m)*(a + a*Sec[e + f*x])^m*Tan[e + f*x])/(f*(
1 + m)*(2 + m)) + ((a + a*Sec[e + f*x])^(1 + m)*Tan[e + f*x])/(a*f*(2 + m))

Rule 71

Int[((a_) + (b_.)*(x_))^(m_)*((c_) + (d_.)*(x_))^(n_), x_Symbol] :> Simp[((a + b*x)^(m + 1)/(b*(m + 1)*(b/(b*c
 - a*d))^n))*Hypergeometric2F1[-n, m + 1, m + 2, (-d)*((a + b*x)/(b*c - a*d))], x] /; FreeQ[{a, b, c, d, m, n}
, x] && NeQ[b*c - a*d, 0] &&  !IntegerQ[m] &&  !IntegerQ[n] && GtQ[b/(b*c - a*d), 0] && (RationalQ[m] ||  !(Ra
tionalQ[n] && GtQ[-d/(b*c - a*d), 0]))

Rule 3885

Int[csc[(e_.) + (f_.)*(x_)]^3*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_), x_Symbol] :> Simp[(-Cot[e + f*x])*(
(a + b*Csc[e + f*x])^(m + 1)/(b*f*(m + 2))), x] + Dist[1/(b*(m + 2)), Int[Csc[e + f*x]*(a + b*Csc[e + f*x])^m*
(b*(m + 1) - a*Csc[e + f*x]), x], x] /; FreeQ[{a, b, e, f, m}, x] && EqQ[a^2 - b^2, 0] &&  !LtQ[m, -2^(-1)]

Rule 3912

Int[(csc[(e_.) + (f_.)*(x_)]*(d_.))^(n_.)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_), x_Symbol] :> Dist[a^2*d
*(Cot[e + f*x]/(f*Sqrt[a + b*Csc[e + f*x]]*Sqrt[a - b*Csc[e + f*x]])), Subst[Int[(d*x)^(n - 1)*((a + b*x)^(m -
 1/2)/Sqrt[a - b*x]), x], x, Csc[e + f*x]], x] /; FreeQ[{a, b, d, e, f, m, n}, x] && EqQ[a^2 - b^2, 0] &&  !In
tegerQ[m] && GtQ[a, 0]

Rule 3913

Int[(csc[(e_.) + (f_.)*(x_)]*(d_.))^(n_.)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_), x_Symbol] :> Dist[a^Int
Part[m]*((a + b*Csc[e + f*x])^FracPart[m]/(1 + (b/a)*Csc[e + f*x])^FracPart[m]), Int[(1 + (b/a)*Csc[e + f*x])^
m*(d*Csc[e + f*x])^n, x], x] /; FreeQ[{a, b, d, e, f, m, n}, x] && EqQ[a^2 - b^2, 0] &&  !IntegerQ[m] &&  !GtQ
[a, 0]

Rule 4086

Int[csc[(e_.) + (f_.)*(x_)]*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_)*(csc[(e_.) + (f_.)*(x_)]*(B_.) + (A_))
, x_Symbol] :> Simp[(-B)*Cot[e + f*x]*((a + b*Csc[e + f*x])^m/(f*(m + 1))), x] + Dist[(a*B*m + A*b*(m + 1))/(b
*(m + 1)), Int[Csc[e + f*x]*(a + b*Csc[e + f*x])^m, x], x] /; FreeQ[{a, b, A, B, e, f, m}, x] && NeQ[A*b - a*B
, 0] && EqQ[a^2 - b^2, 0] && NeQ[a*B*m + A*b*(m + 1), 0] &&  !LtQ[m, -2^(-1)]

Rubi steps

\begin {align*} \int \sec ^3(e+f x) (a+a \sec (e+f x))^m \, dx &=\frac {(a+a \sec (e+f x))^{1+m} \tan (e+f x)}{a f (2+m)}+\frac {\int \sec (e+f x) (a (1+m)-a \sec (e+f x)) (a+a \sec (e+f x))^m \, dx}{a (2+m)}\\ &=-\frac {(a+a \sec (e+f x))^m \tan (e+f x)}{f \left (2+3 m+m^2\right )}+\frac {(a+a \sec (e+f x))^{1+m} \tan (e+f x)}{a f (2+m)}+\frac {\left (1+m+m^2\right ) \int \sec (e+f x) (a+a \sec (e+f x))^m \, dx}{(1+m) (2+m)}\\ &=-\frac {(a+a \sec (e+f x))^m \tan (e+f x)}{f \left (2+3 m+m^2\right )}+\frac {(a+a \sec (e+f x))^{1+m} \tan (e+f x)}{a f (2+m)}+\frac {\left (\left (1+m+m^2\right ) (1+\sec (e+f x))^{-m} (a+a \sec (e+f x))^m\right ) \int \sec (e+f x) (1+\sec (e+f x))^m \, dx}{(1+m) (2+m)}\\ &=-\frac {(a+a \sec (e+f x))^m \tan (e+f x)}{f \left (2+3 m+m^2\right )}+\frac {(a+a \sec (e+f x))^{1+m} \tan (e+f x)}{a f (2+m)}-\frac {\left (\left (1+m+m^2\right ) (1+\sec (e+f x))^{-\frac {1}{2}-m} (a+a \sec (e+f x))^m \tan (e+f x)\right ) \text {Subst}\left (\int \frac {(1+x)^{-\frac {1}{2}+m}}{\sqrt {1-x}} \, dx,x,\sec (e+f x)\right )}{f (1+m) (2+m) \sqrt {1-\sec (e+f x)}}\\ &=-\frac {(a+a \sec (e+f x))^m \tan (e+f x)}{f \left (2+3 m+m^2\right )}+\frac {2^{\frac {1}{2}+m} \left (1+m+m^2\right ) \, _2F_1\left (\frac {1}{2},\frac {1}{2}-m;\frac {3}{2};\frac {1}{2} (1-\sec (e+f x))\right ) (1+\sec (e+f x))^{-\frac {1}{2}-m} (a+a \sec (e+f x))^m \tan (e+f x)}{f (1+m) (2+m)}+\frac {(a+a \sec (e+f x))^{1+m} \tan (e+f x)}{a f (2+m)}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.67, size = 123, normalized size = 0.79 \begin {gather*} \frac {(1+\sec (e+f x))^{-\frac {1}{2}-m} (a (1+\sec (e+f x)))^m \left (2^{\frac {3}{2}+m} \left (1+m+m^2\right ) \, _2F_1\left (\frac {1}{2},-\frac {1}{2}-m;\frac {3}{2};\frac {1}{2} (1-\sec (e+f x))\right )+(1+\sec (e+f x))^{\frac {1}{2}+m} (-1+m+(1+2 m) \sec (e+f x))\right ) \tan (e+f x)}{f (2+m) (1+2 m)} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[Sec[e + f*x]^3*(a + a*Sec[e + f*x])^m,x]

[Out]

((1 + Sec[e + f*x])^(-1/2 - m)*(a*(1 + Sec[e + f*x]))^m*(2^(3/2 + m)*(1 + m + m^2)*Hypergeometric2F1[1/2, -1/2
 - m, 3/2, (1 - Sec[e + f*x])/2] + (1 + Sec[e + f*x])^(1/2 + m)*(-1 + m + (1 + 2*m)*Sec[e + f*x]))*Tan[e + f*x
])/(f*(2 + m)*(1 + 2*m))

________________________________________________________________________________________

Maple [F]
time = 0.07, size = 0, normalized size = 0.00 \[\int \left (\sec ^{3}\left (f x +e \right )\right ) \left (a +a \sec \left (f x +e \right )\right )^{m}\, dx\]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sec(f*x+e)^3*(a+a*sec(f*x+e))^m,x)

[Out]

int(sec(f*x+e)^3*(a+a*sec(f*x+e))^m,x)

________________________________________________________________________________________

Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(f*x+e)^3*(a+a*sec(f*x+e))^m,x, algorithm="maxima")

[Out]

integrate((a*sec(f*x + e) + a)^m*sec(f*x + e)^3, x)

________________________________________________________________________________________

Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(f*x+e)^3*(a+a*sec(f*x+e))^m,x, algorithm="fricas")

[Out]

integral((a*sec(f*x + e) + a)^m*sec(f*x + e)^3, x)

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \left (a \left (\sec {\left (e + f x \right )} + 1\right )\right )^{m} \sec ^{3}{\left (e + f x \right )}\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(f*x+e)**3*(a+a*sec(f*x+e))**m,x)

[Out]

Integral((a*(sec(e + f*x) + 1))**m*sec(e + f*x)**3, x)

________________________________________________________________________________________

Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(f*x+e)^3*(a+a*sec(f*x+e))^m,x, algorithm="giac")

[Out]

integrate((a*sec(f*x + e) + a)^m*sec(f*x + e)^3, x)

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {{\left (a+\frac {a}{\cos \left (e+f\,x\right )}\right )}^m}{{\cos \left (e+f\,x\right )}^3} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a + a/cos(e + f*x))^m/cos(e + f*x)^3,x)

[Out]

int((a + a/cos(e + f*x))^m/cos(e + f*x)^3, x)

________________________________________________________________________________________